3.201 \(\int \frac{(a+b x+c x^2)^{3/2} (d+e x+f x^2)}{(g+h x)^2} \, dx\)

Optimal. Leaf size=754 \[ \frac{\tanh ^{-1}\left (\frac{b+2 c x}{2 \sqrt{c} \sqrt{a+b x+c x^2}}\right ) \left (48 c^2 h^2 \left (a^2 f h^2-2 a b h (2 f g-e h)+b^2 \left (d h^2-2 e g h+3 f g^2\right )\right )+8 b^2 c h^3 (-3 a f h-b e h+2 b f g)+192 c^3 h \left (a h \left (d h^2-2 e g h+3 f g^2\right )-b g \left (2 d h^2-3 e g h+4 f g^2\right )\right )+3 b^4 f h^4+128 c^4 g^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{128 c^{5/2} h^6}-\frac{\sqrt{a+b x+c x^2} \left (2 c h x \left (4 c h (-3 a f h-2 b e h+4 b f g)+3 b^2 f h^2-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )+16 c^2 h \left (4 a h (2 f g-e h)-b \left (9 d h^2-14 e g h+19 f g^2\right )\right )+4 b c h^2 (-3 a f h-2 b e h+4 b f g)+3 b^3 f h^3+64 c^3 g \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{64 c^2 h^5}-\frac{\left (a+b x+c x^2\right )^{3/2} \left (6 c h^2 x \left (-a f h+b f g-4 c d h+4 c e g-\frac{5 c f g^2}{h}\right )+c h \left (8 a h (2 f g-e h)-b \left (43 f g^2-8 h (4 e g-3 d h)\right )\right )+3 b f h^2 (b g-a h)+8 c^2 g \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{24 c h^3 \left (a h^2-b g h+c g^2\right )}-\frac{\left (a+b x+c x^2\right )^{5/2} \left (f g^2-h (e g-d h)\right )}{h (g+h x) \left (a h^2-b g h+c g^2\right )}-\frac{\sqrt{a h^2-b g h+c g^2} \tanh ^{-1}\left (\frac{-2 a h+x (2 c g-b h)+b g}{2 \sqrt{a+b x+c x^2} \sqrt{a h^2-b g h+c g^2}}\right ) \left (h \left (2 a h (2 f g-e h)-b \left (3 d h^2-5 e g h+7 f g^2\right )\right )+2 c g \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{2 h^6} \]

[Out]

-((3*b^3*f*h^3 + 4*b*c*h^2*(4*b*f*g - 2*b*e*h - 3*a*f*h) + 64*c^3*g*(5*f*g^2 - h*(4*e*g - 3*d*h)) + 16*c^2*h*(
4*a*h*(2*f*g - e*h) - b*(19*f*g^2 - 14*e*g*h + 9*d*h^2)) + 2*c*h*(3*b^2*f*h^2 + 4*c*h*(4*b*f*g - 2*b*e*h - 3*a
*f*h) - 16*c^2*(5*f*g^2 - h*(4*e*g - 3*d*h)))*x)*Sqrt[a + b*x + c*x^2])/(64*c^2*h^5) - ((3*b*f*h^2*(b*g - a*h)
 + 8*c^2*g*(5*f*g^2 - h*(4*e*g - 3*d*h)) + c*h*(8*a*h*(2*f*g - e*h) - b*(43*f*g^2 - 8*h*(4*e*g - 3*d*h))) + 6*
c*h^2*(4*c*e*g + b*f*g - (5*c*f*g^2)/h - 4*c*d*h - a*f*h)*x)*(a + b*x + c*x^2)^(3/2))/(24*c*h^3*(c*g^2 - b*g*h
 + a*h^2)) - ((f*g^2 - h*(e*g - d*h))*(a + b*x + c*x^2)^(5/2))/(h*(c*g^2 - b*g*h + a*h^2)*(g + h*x)) + ((3*b^4
*f*h^4 + 8*b^2*c*h^3*(2*b*f*g - b*e*h - 3*a*f*h) + 128*c^4*g^2*(5*f*g^2 - h*(4*e*g - 3*d*h)) + 48*c^2*h^2*(a^2
*f*h^2 - 2*a*b*h*(2*f*g - e*h) + b^2*(3*f*g^2 - 2*e*g*h + d*h^2)) + 192*c^3*h*(a*h*(3*f*g^2 - 2*e*g*h + d*h^2)
 - b*g*(4*f*g^2 - 3*e*g*h + 2*d*h^2)))*ArcTanh[(b + 2*c*x)/(2*Sqrt[c]*Sqrt[a + b*x + c*x^2])])/(128*c^(5/2)*h^
6) - (Sqrt[c*g^2 - b*g*h + a*h^2]*(2*c*g*(5*f*g^2 - h*(4*e*g - 3*d*h)) + h*(2*a*h*(2*f*g - e*h) - b*(7*f*g^2 -
 5*e*g*h + 3*d*h^2)))*ArcTanh[(b*g - 2*a*h + (2*c*g - b*h)*x)/(2*Sqrt[c*g^2 - b*g*h + a*h^2]*Sqrt[a + b*x + c*
x^2])])/(2*h^6)

________________________________________________________________________________________

Rubi [A]  time = 2.50327, antiderivative size = 750, normalized size of antiderivative = 0.99, number of steps used = 8, number of rules used = 6, integrand size = 32, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.188, Rules used = {1650, 814, 843, 621, 206, 724} \[ \frac{\tanh ^{-1}\left (\frac{b+2 c x}{2 \sqrt{c} \sqrt{a+b x+c x^2}}\right ) \left (48 c^2 h^2 \left (a^2 f h^2-2 a b h (2 f g-e h)+b^2 \left (d h^2-2 e g h+3 f g^2\right )\right )+8 b^2 c h^3 (-3 a f h-b e h+2 b f g)+192 c^3 h \left (a h \left (d h^2-2 e g h+3 f g^2\right )-b g \left (2 d h^2-3 e g h+4 f g^2\right )\right )+3 b^4 f h^4+128 c^4 \left (5 f g^4-g^2 h (4 e g-3 d h)\right )\right )}{128 c^{5/2} h^6}-\frac{\sqrt{a+b x+c x^2} \left (2 c h x \left (4 c h (-3 a f h-2 b e h+4 b f g)+3 b^2 f h^2-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )-16 c^2 h \left (-4 a h (2 f g-e h)-b h (14 e g-9 d h)+19 b f g^2\right )+4 b c h^2 (-3 a f h-2 b e h+4 b f g)+3 b^3 f h^3+64 c^3 \left (5 f g^3-g h (4 e g-3 d h)\right )\right )}{64 c^2 h^5}-\frac{\left (a+b x+c x^2\right )^{3/2} \left (6 c h x \left (-a f h+b f g-4 c d h+4 c e g-\frac{5 c f g^2}{h}\right )-c \left (-8 a h (2 f g-e h)-8 b h (4 e g-3 d h)+43 b f g^2\right )+3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}\right )}{24 c h^2 \left (a h^2-b g h+c g^2\right )}-\frac{\left (a+b x+c x^2\right )^{5/2} \left (f g^2-h (e g-d h)\right )}{h (g+h x) \left (a h^2-b g h+c g^2\right )}-\frac{\sqrt{a h^2-b g h+c g^2} \tanh ^{-1}\left (\frac{-2 a h+x (2 c g-b h)+b g}{2 \sqrt{a+b x+c x^2} \sqrt{a h^2-b g h+c g^2}}\right ) \left (2 c \left (5 f g^3-g h (4 e g-3 d h)\right )-h \left (-2 a h (2 f g-e h)-b h (5 e g-3 d h)+7 b f g^2\right )\right )}{2 h^6} \]

Antiderivative was successfully verified.

[In]

Int[((a + b*x + c*x^2)^(3/2)*(d + e*x + f*x^2))/(g + h*x)^2,x]

[Out]

-((3*b^3*f*h^3 + 4*b*c*h^2*(4*b*f*g - 2*b*e*h - 3*a*f*h) + 64*c^3*(5*f*g^3 - g*h*(4*e*g - 3*d*h)) - 16*c^2*h*(
19*b*f*g^2 - b*h*(14*e*g - 9*d*h) - 4*a*h*(2*f*g - e*h)) + 2*c*h*(3*b^2*f*h^2 + 4*c*h*(4*b*f*g - 2*b*e*h - 3*a
*f*h) - 16*c^2*(5*f*g^2 - h*(4*e*g - 3*d*h)))*x)*Sqrt[a + b*x + c*x^2])/(64*c^2*h^5) - ((3*b*f*h*(b*g - a*h) +
 (8*c^2*(5*f*g^3 - g*h*(4*e*g - 3*d*h)))/h - c*(43*b*f*g^2 - 8*b*h*(4*e*g - 3*d*h) - 8*a*h*(2*f*g - e*h)) + 6*
c*h*(4*c*e*g + b*f*g - (5*c*f*g^2)/h - 4*c*d*h - a*f*h)*x)*(a + b*x + c*x^2)^(3/2))/(24*c*h^2*(c*g^2 - b*g*h +
 a*h^2)) - ((f*g^2 - h*(e*g - d*h))*(a + b*x + c*x^2)^(5/2))/(h*(c*g^2 - b*g*h + a*h^2)*(g + h*x)) + ((3*b^4*f
*h^4 + 8*b^2*c*h^3*(2*b*f*g - b*e*h - 3*a*f*h) + 128*c^4*(5*f*g^4 - g^2*h*(4*e*g - 3*d*h)) + 48*c^2*h^2*(a^2*f
*h^2 - 2*a*b*h*(2*f*g - e*h) + b^2*(3*f*g^2 - 2*e*g*h + d*h^2)) + 192*c^3*h*(a*h*(3*f*g^2 - 2*e*g*h + d*h^2) -
 b*g*(4*f*g^2 - 3*e*g*h + 2*d*h^2)))*ArcTanh[(b + 2*c*x)/(2*Sqrt[c]*Sqrt[a + b*x + c*x^2])])/(128*c^(5/2)*h^6)
 - (Sqrt[c*g^2 - b*g*h + a*h^2]*(2*c*(5*f*g^3 - g*h*(4*e*g - 3*d*h)) - h*(7*b*f*g^2 - b*h*(5*e*g - 3*d*h) - 2*
a*h*(2*f*g - e*h)))*ArcTanh[(b*g - 2*a*h + (2*c*g - b*h)*x)/(2*Sqrt[c*g^2 - b*g*h + a*h^2]*Sqrt[a + b*x + c*x^
2])])/(2*h^6)

Rule 1650

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = Polynomia
lQuotient[Pq, d + e*x, x], R = PolynomialRemainder[Pq, d + e*x, x]}, Simp[(e*R*(d + e*x)^(m + 1)*(a + b*x + c*
x^2)^(p + 1))/((m + 1)*(c*d^2 - b*d*e + a*e^2)), x] + Dist[1/((m + 1)*(c*d^2 - b*d*e + a*e^2)), Int[(d + e*x)^
(m + 1)*(a + b*x + c*x^2)^p*ExpandToSum[(m + 1)*(c*d^2 - b*d*e + a*e^2)*Q + c*d*R*(m + 1) - b*e*R*(m + p + 2)
- c*e*R*(m + 2*p + 3)*x, x], x], x]] /; FreeQ[{a, b, c, d, e, p}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] &&
 NeQ[c*d^2 - b*d*e + a*e^2, 0] && LtQ[m, -1]

Rule 814

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Sim
p[((d + e*x)^(m + 1)*(c*e*f*(m + 2*p + 2) - g*(c*d + 2*c*d*p - b*e*p) + g*c*e*(m + 2*p + 1)*x)*(a + b*x + c*x^
2)^p)/(c*e^2*(m + 2*p + 1)*(m + 2*p + 2)), x] - Dist[p/(c*e^2*(m + 2*p + 1)*(m + 2*p + 2)), Int[(d + e*x)^m*(a
 + b*x + c*x^2)^(p - 1)*Simp[c*e*f*(b*d - 2*a*e)*(m + 2*p + 2) + g*(a*e*(b*e - 2*c*d*m + b*e*m) + b*d*(b*e*p -
 c*d - 2*c*d*p)) + (c*e*f*(2*c*d - b*e)*(m + 2*p + 2) + g*(b^2*e^2*(p + m + 1) - 2*c^2*d^2*(1 + 2*p) - c*e*(b*
d*(m - 2*p) + 2*a*e*(m + 2*p + 1))))*x, x], x], x] /; FreeQ[{a, b, c, d, e, f, g, m}, x] && NeQ[b^2 - 4*a*c, 0
] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && GtQ[p, 0] && (IntegerQ[p] ||  !RationalQ[m] || (GeQ[m, -1] && LtQ[m, 0])
) &&  !ILtQ[m + 2*p, 0] && (IntegerQ[m] || IntegerQ[p] || IntegersQ[2*m, 2*p])

Rule 843

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Dis
t[g/e, Int[(d + e*x)^(m + 1)*(a + b*x + c*x^2)^p, x], x] + Dist[(e*f - d*g)/e, Int[(d + e*x)^m*(a + b*x + c*x^
2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g, m, p}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0]
&&  !IGtQ[m, 0]

Rule 621

Int[1/Sqrt[(a_) + (b_.)*(x_) + (c_.)*(x_)^2], x_Symbol] :> Dist[2, Subst[Int[1/(4*c - x^2), x], x, (b + 2*c*x)
/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 724

Int[1/(((d_.) + (e_.)*(x_))*Sqrt[(a_.) + (b_.)*(x_) + (c_.)*(x_)^2]), x_Symbol] :> Dist[-2, Subst[Int[1/(4*c*d
^2 - 4*b*d*e + 4*a*e^2 - x^2), x], x, (2*a*e - b*d - (2*c*d - b*e)*x)/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a,
b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[2*c*d - b*e, 0]

Rubi steps

\begin{align*} \int \frac{\left (a+b x+c x^2\right )^{3/2} \left (d+e x+f x^2\right )}{(g+h x)^2} \, dx &=-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}-\frac{\int \frac{\left (\frac{1}{2} \left (-2 c d g+5 b e g+2 a f g-\frac{5 b f g^2}{h}-3 b d h-2 a e h\right )+\left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{g+h x} \, dx}{c g^2-b g h+a h^2}\\ &=-\frac{\left (3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}-c \left (43 b f g^2-8 b h (4 e g-3 d h)-8 a h (2 f g-e h)\right )+6 c h \left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{24 c h^2 \left (c g^2-b g h+a h^2\right )}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}+\frac{\int \frac{\left (-\frac{\left (c g^2-b g h+a h^2\right ) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{2 h}-\frac{\left (c g^2-b g h+a h^2\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right ) x}{2 h}\right ) \sqrt{a+b x+c x^2}}{g+h x} \, dx}{8 c h^2 \left (c g^2-b g h+a h^2\right )}\\ &=-\frac{\left (3 b^3 f h^3+4 b c h^2 (4 b f g-2 b e h-3 a f h)+64 c^3 \left (5 f g^3-g h (4 e g-3 d h)\right )-16 c^2 h \left (19 b f g^2-b h (14 e g-9 d h)-4 a h (2 f g-e h)\right )+2 c h \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right ) x\right ) \sqrt{a+b x+c x^2}}{64 c^2 h^5}-\frac{\left (3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}-c \left (43 b f g^2-8 b h (4 e g-3 d h)-8 a h (2 f g-e h)\right )+6 c h \left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{24 c h^2 \left (c g^2-b g h+a h^2\right )}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}-\frac{\int \frac{-\frac{1}{4} \left (c g^2-b g h+a h^2\right ) \left (4 c (b g-2 a h) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )-\frac{g \left (4 b c g-b^2 h-4 a c h\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{h}\right )-\frac{1}{4} \left (c g^2-b g h+a h^2\right ) \left (4 c (2 c g-b h) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )-\frac{\left (8 c^2 g^2-b^2 h^2-4 c h (b g-a h)\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{h}\right ) x}{(g+h x) \sqrt{a+b x+c x^2}} \, dx}{32 c^2 h^4 \left (c g^2-b g h+a h^2\right )}\\ &=-\frac{\left (3 b^3 f h^3+4 b c h^2 (4 b f g-2 b e h-3 a f h)+64 c^3 \left (5 f g^3-g h (4 e g-3 d h)\right )-16 c^2 h \left (19 b f g^2-b h (14 e g-9 d h)-4 a h (2 f g-e h)\right )+2 c h \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right ) x\right ) \sqrt{a+b x+c x^2}}{64 c^2 h^5}-\frac{\left (3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}-c \left (43 b f g^2-8 b h (4 e g-3 d h)-8 a h (2 f g-e h)\right )+6 c h \left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{24 c h^2 \left (c g^2-b g h+a h^2\right )}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}-\frac{\left (\left (c g^2-b g h+a h^2\right ) \left (2 c \left (5 f g^3-g h (4 e g-3 d h)\right )-h \left (7 b f g^2-b h (5 e g-3 d h)-2 a h (2 f g-e h)\right )\right )\right ) \int \frac{1}{(g+h x) \sqrt{a+b x+c x^2}} \, dx}{2 h^6}+\frac{\left (4 c (2 c g-b h) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )-\frac{\left (8 c^2 g^2-b^2 h^2-4 c h (b g-a h)\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{h}\right ) \int \frac{1}{\sqrt{a+b x+c x^2}} \, dx}{128 c^2 h^5}\\ &=-\frac{\left (3 b^3 f h^3+4 b c h^2 (4 b f g-2 b e h-3 a f h)+64 c^3 \left (5 f g^3-g h (4 e g-3 d h)\right )-16 c^2 h \left (19 b f g^2-b h (14 e g-9 d h)-4 a h (2 f g-e h)\right )+2 c h \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right ) x\right ) \sqrt{a+b x+c x^2}}{64 c^2 h^5}-\frac{\left (3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}-c \left (43 b f g^2-8 b h (4 e g-3 d h)-8 a h (2 f g-e h)\right )+6 c h \left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{24 c h^2 \left (c g^2-b g h+a h^2\right )}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}+\frac{\left (\left (c g^2-b g h+a h^2\right ) \left (2 c \left (5 f g^3-g h (4 e g-3 d h)\right )-h \left (7 b f g^2-b h (5 e g-3 d h)-2 a h (2 f g-e h)\right )\right )\right ) \operatorname{Subst}\left (\int \frac{1}{4 c g^2-4 b g h+4 a h^2-x^2} \, dx,x,\frac{-b g+2 a h-(2 c g-b h) x}{\sqrt{a+b x+c x^2}}\right )}{h^6}+\frac{\left (4 c (2 c g-b h) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )-\frac{\left (8 c^2 g^2-b^2 h^2-4 c h (b g-a h)\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{h}\right ) \operatorname{Subst}\left (\int \frac{1}{4 c-x^2} \, dx,x,\frac{b+2 c x}{\sqrt{a+b x+c x^2}}\right )}{64 c^2 h^5}\\ &=-\frac{\left (3 b^3 f h^3+4 b c h^2 (4 b f g-2 b e h-3 a f h)+64 c^3 \left (5 f g^3-g h (4 e g-3 d h)\right )-16 c^2 h \left (19 b f g^2-b h (14 e g-9 d h)-4 a h (2 f g-e h)\right )+2 c h \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right ) x\right ) \sqrt{a+b x+c x^2}}{64 c^2 h^5}-\frac{\left (3 b f h (b g-a h)+\frac{8 c^2 \left (5 f g^3-g h (4 e g-3 d h)\right )}{h}-c \left (43 b f g^2-8 b h (4 e g-3 d h)-8 a h (2 f g-e h)\right )+6 c h \left (4 c e g+b f g-\frac{5 c f g^2}{h}-4 c d h-a f h\right ) x\right ) \left (a+b x+c x^2\right )^{3/2}}{24 c h^2 \left (c g^2-b g h+a h^2\right )}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{5/2}}{h \left (c g^2-b g h+a h^2\right ) (g+h x)}+\frac{\left (4 c (2 c g-b h) \left (3 b^2 f g h+4 a c h (5 f g-4 e h)-8 b c \left (5 f g^2-h (4 e g-3 d h)\right )\right )-\frac{\left (8 c^2 g^2-b^2 h^2-4 c h (b g-a h)\right ) \left (3 b^2 f h^2+4 c h (4 b f g-2 b e h-3 a f h)-16 c^2 \left (5 f g^2-h (4 e g-3 d h)\right )\right )}{h}\right ) \tanh ^{-1}\left (\frac{b+2 c x}{2 \sqrt{c} \sqrt{a+b x+c x^2}}\right )}{128 c^{5/2} h^5}-\frac{\sqrt{c g^2-b g h+a h^2} \left (2 c \left (5 f g^3-g h (4 e g-3 d h)\right )-h \left (7 b f g^2-b h (5 e g-3 d h)-2 a h (2 f g-e h)\right )\right ) \tanh ^{-1}\left (\frac{b g-2 a h+(2 c g-b h) x}{2 \sqrt{c g^2-b g h+a h^2} \sqrt{a+b x+c x^2}}\right )}{2 h^6}\\ \end{align*}

Mathematica [A]  time = 4.60272, size = 756, normalized size = 1. \[ -\frac{\frac{\frac{-2 c h \sqrt{a+x (b+c x)} \left (h (a h-b g)+c g^2\right ) \left (-4 c^2 h (a h (8 e h-16 f g+3 f h x)+2 b (h (9 d h-14 e g+e h x)+f g (19 g-2 h x)))+b c h^2 (b (-4 e h+8 f g+3 f h x)-6 a f h)+\frac{3}{2} b^3 f h^3+16 c^3 (2 g-h x) \left (h (3 d h-4 e g)+5 f g^2\right )\right )+\sqrt{c} \left (h (a h-b g)+c g^2\right ) \tanh ^{-1}\left (\frac{b+2 c x}{2 \sqrt{c} \sqrt{a+x (b+c x)}}\right ) \left (\frac{1}{2} \left (4 c h (a h-b g)-b^2 h^2+8 c^2 g^2\right ) \left (4 c h (3 a f h+2 b e h-4 b f g)-3 b^2 f h^2+16 c^2 \left (h (3 d h-4 e g)+5 f g^2\right )\right )+2 c h (2 c g-b h) \left (4 a c h (5 f g-4 e h)+3 b^2 f g h-8 b c \left (h (3 d h-4 e g)+5 f g^2\right )\right )\right )+32 c^3 \left (h (a h-b g)+c g^2\right )^{3/2} \tanh ^{-1}\left (\frac{2 a h-b g+b h x-2 c g x}{2 \sqrt{a+x (b+c x)} \sqrt{h (a h-b g)+c g^2}}\right ) \left (h \left (-2 a h (e h-2 f g)+b h (5 e g-3 d h)-7 b f g^2\right )+2 c \left (g h (3 d h-4 e g)+5 f g^3\right )\right )}{16 c^2 h^5}+\frac{(a+x (b+c x))^{3/2} \left (c h (2 a h (4 e h-8 f g+3 f h x)+8 b h (3 d h-4 e g)+b f g (43 g-6 h x))+3 b f h^2 (a h-b g)+c^2 \left (8 h (3 d h (h x-g)+e g (4 g-3 h x))+10 f g^2 (3 h x-4 g)\right )\right )}{6 h^2}}{h (b g-a h)-c g^2}+\frac{(a+x (b+c x))^{5/2} \left (f h (a h-b g)+4 c h (d h-e g)+5 c f g^2\right )}{(g+h x) \left (h (a h-b g)+c g^2\right )}-\frac{f (a+x (b+c x))^{5/2}}{g+h x}}{4 c h} \]

Antiderivative was successfully verified.

[In]

Integrate[((a + b*x + c*x^2)^(3/2)*(d + e*x + f*x^2))/(g + h*x)^2,x]

[Out]

-(-((f*(a + x*(b + c*x))^(5/2))/(g + h*x)) + ((5*c*f*g^2 + f*h*(-(b*g) + a*h) + 4*c*h*(-(e*g) + d*h))*(a + x*(
b + c*x))^(5/2))/((c*g^2 + h*(-(b*g) + a*h))*(g + h*x)) + (((a + x*(b + c*x))^(3/2)*(3*b*f*h^2*(-(b*g) + a*h)
+ c*h*(8*b*h*(-4*e*g + 3*d*h) + b*f*g*(43*g - 6*h*x) + 2*a*h*(-8*f*g + 4*e*h + 3*f*h*x)) + c^2*(10*f*g^2*(-4*g
 + 3*h*x) + 8*h*(e*g*(4*g - 3*h*x) + 3*d*h*(-g + h*x)))))/(6*h^2) + (-2*c*h*(c*g^2 + h*(-(b*g) + a*h))*Sqrt[a
+ x*(b + c*x)]*((3*b^3*f*h^3)/2 + 16*c^3*(5*f*g^2 + h*(-4*e*g + 3*d*h))*(2*g - h*x) + b*c*h^2*(-6*a*f*h + b*(8
*f*g - 4*e*h + 3*f*h*x)) - 4*c^2*h*(a*h*(-16*f*g + 8*e*h + 3*f*h*x) + 2*b*(f*g*(19*g - 2*h*x) + h*(-14*e*g + 9
*d*h + e*h*x)))) + Sqrt[c]*(c*g^2 + h*(-(b*g) + a*h))*(2*c*h*(2*c*g - b*h)*(3*b^2*f*g*h + 4*a*c*h*(5*f*g - 4*e
*h) - 8*b*c*(5*f*g^2 + h*(-4*e*g + 3*d*h))) + ((8*c^2*g^2 - b^2*h^2 + 4*c*h*(-(b*g) + a*h))*(-3*b^2*f*h^2 + 4*
c*h*(-4*b*f*g + 2*b*e*h + 3*a*f*h) + 16*c^2*(5*f*g^2 + h*(-4*e*g + 3*d*h))))/2)*ArcTanh[(b + 2*c*x)/(2*Sqrt[c]
*Sqrt[a + x*(b + c*x)])] + 32*c^3*(c*g^2 + h*(-(b*g) + a*h))^(3/2)*(2*c*(5*f*g^3 + g*h*(-4*e*g + 3*d*h)) + h*(
-7*b*f*g^2 + b*h*(5*e*g - 3*d*h) - 2*a*h*(-2*f*g + e*h)))*ArcTanh[(-(b*g) + 2*a*h - 2*c*g*x + b*h*x)/(2*Sqrt[c
*g^2 + h*(-(b*g) + a*h)]*Sqrt[a + x*(b + c*x)])])/(16*c^2*h^5))/(-(c*g^2) + h*(b*g - a*h)))/(4*c*h)

________________________________________________________________________________________

Maple [B]  time = 0.264, size = 14734, normalized size = 19.5 \begin{align*} \text{output too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c*x^2+b*x+a)^(3/2)*(f*x^2+e*x+d)/(h*x+g)^2,x)

[Out]

result too large to display

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)^(3/2)*(f*x^2+e*x+d)/(h*x+g)^2,x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)^(3/2)*(f*x^2+e*x+d)/(h*x+g)^2,x, algorithm="fricas")

[Out]

Timed out

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x**2+b*x+a)**(3/2)*(f*x**2+e*x+d)/(h*x+g)**2,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)^(3/2)*(f*x^2+e*x+d)/(h*x+g)^2,x, algorithm="giac")

[Out]

Timed out